/*
 * @Author: LiuShuang
 * @Date: 2023-03-02 10:57:55
 * @FilePath: \network\src\router\index.js
 * @Description:
 */
import Vue from "vue";
import VueRouter from "vue-router";
import login from "../views/login/index";

Vue.use(VueRouter)

const router = new VueRouter({
  mode: 'history', // 去掉url中的#
  routes: [
    {
      path: "/",
      redirect: "/login"
    }, {
      path: "/home",
      component: ()=> import('@/views/home/index.vue'),
      name: 'home'
    },
    {
      path: "/login",
      name: 'login',
      component: login,
      meta: {
        title: '登录',
        login: false
      }
    },
    {
      path: "/map",
      name: 'map',
      component: ()=> import('@/views/components/map/index.vue'),
      meta: {
        title: '地图',
        login: true
      }
    },
    {
      path: "/dataOverview",
      name: 'dataOverview',
      component: ()=> import('@/views/dataOverview/index.vue'),
      meta: {
        title: '数据预览',
        login: true
      }
    },
    {
      path: "/insDataManage",
      name: 'insDataManage',
      component: ()=> import('@/views/insDataManage/index.vue'),
      meta: {
        title: '机构数据管理',
        login: true
      }
    },
    {
      path: "/evaluateComparison",
      name: 'evaluateComparison',
      component: ()=> import('@/views/evaluateComparison/index.vue'),
      meta: {
        title: '数据对比',
        login: true
      }
    },
  ]
})

export default router
